<template>
    <div class="h-full flex flex-col gap-2">
        <div class="p-2 flex justify-between items-center">
            <div class="text-md font-bold">Prompt {{  t('aigcApp.prompt')}}</div>
        </div>
        <div class="p-4 pt-0 h-full mb-10">
            <textarea 
                v-model="appStore.info.prompt"
                class="h-full w-full bg-transparent"
                @blur="onUpdate"
                >
            </textarea>
        </div>
    </div>
</template>   
<script setup lang="ts">
import { useI18n } from 'vue-i18n';
import { useAppStore } from '/@/stores/aigc/appStore';
    const appStore=useAppStore();
    const {t}=useI18n();
    const emit=defineEmits(['update']);

    async function onUpdate(){
        emit('update');
    }
</script>